# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Daniel Wallace <danielwallace at gtmanfred dot com>

pkgname=python-novaclient
pkgver=18.3.0
_commit=85e4f08309490fa2ab6f0b581b3d645d2dbb5c4b
pkgrel=3
pkgdesc="Client library for OpenStack Compute API"
arch=('any')
url="https://docs.openstack.org/python-novaclient/latest/"
license=('Apache')
depends=('python-six' 'python-pbr' 'python-babel' 'python-prettytable' 'python-keystoneauth1'
         'python-requests' 'python-iso8601' 'python-oslo-utils' 'python-oslo-i18n'
         'python-oslo-serialization')
makedepends=('git' 'python-setuptools')
checkdepends=('python-oslotest' 'python-osprofiler' 'python-requests-mock' 'python-ddt' 'python-stestr' 'python-testscenarios')
source=("git+https://github.com/openstack/python-novaclient.git#commit=$_commit")
sha512sums=('SKIP')

build() {
  cd python-novaclient
  python setup.py build
}

check() {
  cd python-novaclient
  stestr run
}

package() {
  cd python-novaclient
  python setup.py install --root="$pkgdir" --optimize=1
}
